package GaoYuXuan.Homework0715;

import java.util.Arrays;

/**
 * @author 盖
 * @version 1.0
 * @since 2022-07-15 23:04:57
 */
public class ClassDemo2 {
    public static void main(String[] args) {
        byte[] bytes = {95,96,97,98,99,100};
        String s1 = new String(bytes);
        System.out.println(s1);
        String s2 = new String(bytes,1,3);
        System.out.println(s2);
        char[] chars = {'A',68,'G',99,'!'};
        String s3 = new String(chars);
        System.out.println(s3);
        String name = "认真学习";
        byte[] namebytes = name.getBytes();
        System.out.println(Arrays.toString(namebytes));
    }
}